package com.imu.chatmodule;

import com.imu.chatmodule.LongConnection.CommunicationServer;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.CommandLineRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

import javax.annotation.Resource;

@MapperScan("com.imu.chatmodule.ab.mapper")
@SpringBootApplication
public class ChatModuleApplication implements CommandLineRunner {

    @Resource
    CommunicationServer nettyServer;

    public static void main(String[] args) {
        SpringApplication.run(ChatModuleApplication.class, args);
    }

    @Override
    public void run(String... args) throws Exception {
        nettyServer.run(8889);
    }
}
